package com.papers.juan.domain.bo;

import com.papers.common.core.domain.BaseEntity;
import com.papers.common.core.validate.AddGroup;
import com.papers.common.core.validate.EditGroup;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 试卷业务对象 t_juan_paper
 *
 * @author papers
 * @date 2022-10-17
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class TJuanPaperBo extends BaseEntity {

    /**
     * ID
     */
//    @NotBlank(message = "ID不能为空", groups = { EditGroup.class })
    private String paperId;

    /**
     * 课程ID
     */
//    @NotBlank(message = "课程ID不能为空", groups = {AddGroup.class, EditGroup.class})
    private String courseId;

    /**
     * 组卷ID
     */
//    @NotBlank(message = "组卷ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private String generateId;

    /**
     * 试卷编码
     */
//    @NotBlank(message = "试卷编码不能为空", groups = {AddGroup.class, EditGroup.class})
    private String paperCode;

    /**
     * 试卷名称
     */
    @NotBlank(message = "试卷名称不能为空", groups = {AddGroup.class, EditGroup.class})
    private String paperName;

    /**
     * 试卷类型
     */
//    @NotBlank(message = "试卷类型不能为空", groups = { AddGroup.class, EditGroup.class })
    private String paperType;

    /**
     * 科目
     */
//    @NotBlank(message = "科目不能为空", groups = {AddGroup.class, EditGroup.class})
    private String paperSubject;

    /**
     * 试卷描述
     */
    private String paperDes;

    /**
     * 试卷状态
     */
//    @NotBlank(message = "试卷状态不能为空", groups = {AddGroup.class, EditGroup.class})
    private String paperStatus;

    /**
     * 注意事项
     */
    private String paperAttention;

    /**
     * 是否有密封线
     */
    @NotBlank(message = "是否有密封线不能为空", groups = {AddGroup.class, EditGroup.class})
    private String paperSealLine;


    /**
     * 总分
     */
//    @NotNull(message = "总分不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer paperTotalScore;

    /**
     * 考试时长
     */
    @NotNull(message = "考试时长不能为空", groups = {AddGroup.class, EditGroup.class})
    private Integer paperTime;


    /**
     * 有效截止时间
     */
    private String paperEndTime;

    /**
     * 是否被抽取
     */
    private String isTakenOut;

    /**
     * 难度系数
     */
    @NotNull(message = "难度系数不能为空", groups = {AddGroup.class, EditGroup.class})
    private BigDecimal paperEasy;

    /**
     * 题目信息
     */
    @NotBlank(message = "试卷题目信息不能为空", groups = {AddGroup.class, EditGroup.class})
    private String paperQuestionInfo;

    /**
     * 院系id
     */
    private String departId;

    /**
     * 专业
     */
    private String majorId;

    /**
     * 院系名称
     */
    private String departName;

    /**
     * 专业名称
     */
    private String majorName;

    /**
     * 课程名称
     */
    private String courseSubject;

    /**
     * 用户名
     */
    private String userName;

    /**
     * 创建人
     */
//    @NotBlank(message = "创建人不能为空", groups = { AddGroup.class, EditGroup.class })
    private String createdBy;

    /**
     * 创建时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd")
//    @NotNull(message = "创建时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Date createdTime;

    /**
     * 更新人
     */
//    @NotBlank(message = "更新人不能为空", groups = { AddGroup.class, EditGroup.class })
    private String updatedBy;

    /**
     * 更新时间
     */
//    @NotNull(message = "更新时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Date updatedTime;


}
